package com.sicaolong.io;

import javax.annotation.Resources;
import java.io.InputStream;

/**
 * @author : sicaolong
 * @description :
 * @date : 2020/10/15  11:28 下午
 */
public class Resource {
	/**
	 * 根据配置文件的路径，将配置文件加载成字节输入流，存储到内存中
	 *
	 * @param path
	 * @return
	 */
	public static InputStream getResourceAsStream(String path) {
		InputStream resourceAsStream = Resources.class.getClassLoader().getResourceAsStream(path);
		return resourceAsStream;
	}
}